<?php

class MoodAction extends BaseAction {
	
	public function index() {
		import("ORG.Util.Page");
		$mood = new Model("mood");
		$Page = new Page($mood->count(),10);
		$show = $Page->show();
		
		
		$mood_result = $mood->order("cTime desc")->limit($Page->firstRow.','.$Page->listRows)->select();
		$mood_count = $mood->count();
		$this->assign("moods", $mood_result);
		
		$fonts = array('宋体','幼圆','楷体_GB2312','仿宋_GB2312','隶书','宋体','仿宋_GB2312','仿宋_GB2312','宋体','楷体_GB2312','幼圆','幼圆','幼圆','隶书','隶书','楷体_GB2312','楷体_GB2312');
		$this->assign("fonts", $fonts);
		$d_mood_tag = new Model("mood_tag");
		$mood_tag_list = $d_mood_tag->select();
		
		$this->assign('pages',$show);
		$this->assign("mood_tag_list", $mood_tag_list);
		$this->display("Index:mood");
	}
}
?>